package conn

import (
	"gitee.com/ameise84/e3utils/str_conv"
	"servers/crypto"
)

const (
	Key16 = "ebfc8cc9ebfc8cc9"
	Key32 = "be19bfc8144e3b411ec98c7020c3b07c"
)

var _gDefaultAes crypto.Cipher

func init() {
	_gDefaultAes = crypto.AES(str_conv.ToBytes(Key16))
}

func encrypt(src, dst []byte) ([]byte, error) {
	return _gDefaultAes.Encrypt(src, dst)
}

func decrypt(src, dst []byte) ([]byte, error) {
	return _gDefaultAes.Decrypt(src, dst)
}
